package atguigu03._extends.exer1;

/**
 * ClassName: Kids
 * Package: atguigu03._extends.exer1
 * Description:
 *      - 成员变量int yearsOld；
 *      - 方法printAge()打印yearsOld的值。
 * @Author BuTang
 * @Create 2023/3/6 10:06
 * @Version 1.0
 */
public class Kids extends ManKind{
        private int yearsOld;

    public Kids(int yearsOld) {
        this.yearsOld = yearsOld;
    }

    public Kids(int sex, int salary, int yearsOld) {
        super(sex, salary);
        this.yearsOld = yearsOld;
    }

    public int getYearsOld() {
        return yearsOld;
    }

    public void setYearsOld(int yearsOld) {
        this.yearsOld = yearsOld;
    }

    public Kids() {
    }


}
